Determine the options (both main and sub menu):
[bash]awk ‘BEGIN {submenu=0;menu=0};$1 ~ /submenu/ {submenu+=1;menu=0;sub(/\$.*$/,"");print submenu" " $0};/menuentry / && /Linux/ {gsub(/menuentry/,"");gsub(/–class.*$/,"");gsub(/\047/,"");print " "submenu">"menu " " $0;menu+=1}’ /boot/grub/grub.cfg[/bash]
Change the default to the desired option:
[bash]nano /etc/default/grub[/bash]
Where X>X is the menu item (0 is the top)
This must be in quotes!
Save your new configuration:
[bash]update-grub[/bash]